{include file="kuyou/common/menu" /}
<style>
    #edit-form td{
        text-align: left;
    }
    .explain{
        color: #b9b9b9;
    }
    #edit-form .center{
        text-align: center;
    }
    .table-bordered > thead > tr > th, .table-bordered > tbody > tr > th, .table-bordered > tfoot > tr > th, .table-bordered > thead > tr > td, .table-bordered > tbody > tr > td, .table-bordered > tfoot > tr > td {
        border: 1px solid #dadada;
    }
    #edit-form td{
        text-align: left;
    }
    .panel-body{
        background: #fff;
    }
    .explain{
        color: #b9b9b9;
    }
    #edit-form .center{
        text-align: center;
    }
    .table-bordered > thead > tr > th, .table-bordered > tbody > tr > th, .table-bordered > tfoot > tr > th, .table-bordered > thead > tr > td, .table-bordered > tbody > tr > td, .table-bordered > tfoot > tr > td {
        border: 1px solid #dadada;
    }
    .list_title{
        font-size: 18px;
        margin: 20px 0 10px 0;
        color: #00adff;
    }
    .width120{
        width: 120px;
    }
    .width70{
        width: 70px;
    }
    .layui-tab-title .layui-this {
        color: #18bc9c;
    }
    .layui-tab-title .layui-this:after {
        border: 0;
        border-bottom: solid 2px #18bc9c;
        top: -1px;
    }
    #add-form,#xcx-form{
        max-width: 800px!important;border: solid 1px #d7d7d7;border-top: 0;border-bottom: 0;
        position: relative;
    }
    #edit-form{
        max-width: 800px!important;border: solid 1px #d7d7d7;border-top: 0;border-bottom: 0;
        position: relative;
    }
    .form-group {
        margin-left: 0!important;
        margin-right: 0!important;
        border-top: solid 1px #d7d7d7;
        border-bottom: solid 1px #d7d7d7;
    }
    .form-group input,.form-group select{
        width: 100%;height: 31px;border: 0;outline: none;
    }
    .control-label{
        background: #efefef;
        height: 31px;
        line-height: 31px;
        padding-left: 0;
        padding-top: 0!important;
        text-align: left!important;
        text-indent: 10px;
    }
    .col-xs-12{
        position: relative;
    }
    .btn-default{
        border: 0;outline: none;height: 31px;background: none;
    }
    .sub_btn{
        position: absolute;bottom:-70px;
    }
    #add-form>.form-group,#xcx-form>.form-group{
        margin-bottom: 0;margin-top: 20px;
    }
    #add-form>div:first-child,#xcx-form>div:first-child{
        margin-bottom: 0!important;
    }
    input:disabled, input[disabled]{
        color: #afafaf;
    }
    tips{
        position: absolute;
        width: 500px;
        line-height: 31px;
        right: -505px;
        color: #ff8d00;
    }

    #edit-form,#price-form,#prefix-form{
        position: relative;margin-top: 20px;
    }
    #prefix-form td{
        padding: 0!important;
        height: 30px!important;
        line-height: 30px;
        text-align: center;
    }
    .textLeft{
        text-align: left;
    }
    #prefix-form input[type='checkbox'],#edit-form input[type='checkbox']{
        width: 16px;height: 16px;margin-top: 8px;
    }
    #prefix-form button{
        margin-bottom: 20px;
    }
    #prefix-form input[type='text'],#prefix-form input[type='number']{
        width: 100%;height: 100%;border: none;outline: none;padding-left: 10px;
    }
</style>
<div class="panel panel-default panel-intro">
    <div class="panel-body">
        <div id="myTabContent" class="tab-content">
            <div class="tab-pane fade active in" id="one">
                <div class="widget-body no-padding">

                    <div class="layui-tab">
                        <ul class="layui-tab-title">
                            <li class="layui-this">{:__('Mini program configuration')}</li>
                            <li>{:__('system parameter')}</li>
                        </ul>
                        <div class="layui-tab-content">
                            <div class="layui-tab-item layui-show">
                                <form id="add-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="" style="max-width: 800px;">
                                    {foreach name="sets" item="vo" key="k"}
                                    {if condition="$vo.type==1"}
                                    <div class="form-group">
                                        <label class="control-label col-xs-12 col-sm-2">{$vo.nickname}：</label>
                                        <div class="col-xs-12 col-sm-8">
                                            {if condition="$vo.is_edit<1"}<input type="hidden" value="{$vo.id}" name="row[{$k}][id]">{/if}
                                            <input id="c-{$vo.name}" class="form-control" {if condition="$vo.is_edit<1"}name="row[{$k}][value]"{else/}disabled{/if} value="{$vo.value}" type="text" placeholder="{$vo.nickname}">
                                            {if condition="!empty($vo.notice)"}<tips>{$vo.notice}</tips>{/if}
                                        </div>
                                    </div>
                                    {/if}
                                    {/foreach}
                                    <button type="button" data-id="add-form" class="sub_btn btn btn-success btn-embossed">{:__('OK')}</button>
                                </form>
                            </div>
                            <div class="layui-tab-item">
                                <form id="edit-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="" style="max-width: 800px;">
                                    <input type="hidden" name="row[type]" value="2">
                                    {foreach name="user_config" item="vo" key="k"}
                                    {if condition="$vo.name=='version' || $vo.name=='appid' || $vo.name=='appsecret'"}
                                    {else/}
                                    <div class="form-group" {if condition="$vo.name=='agreement' || $vo.name=='privacy'"}style="padding-top:20px;padding-right:10px;"{/if}>
                                    <label class="control-label col-xs-12 col-sm-2" {if condition="$vo.name=='agreement' || $vo.name=='privacy'"}style="background:none;"{/if}>{$vo.title}：</label>
                                    <div class="col-xs-12 col-sm-10">
                                        <input type="hidden" name="row[configId][]" value="{$vo.id}">
                                        {if condition="$vo.name=='notice' || $vo.name=='indextitle'"}
                                        <input type="text" class="form-control" name="row[config{$vo.id}]" value="{$vo.value}">
                                        {elseif condition="$vo.name=='pay_status'"}
                                        <label style="margin-top: 5px;margin-left: 10px;">{:__('open')}<input type="radio" name="row[config{$vo.id}]" style="width: 15px;height: 15px;margin-top: 3px;" value="1" {if condition="$vo.value==1"}checked="checked"{/if}></label>
                                        <label style="margin-left: 10px;">{:__('close')}<input type="radio" name="row[config{$vo.id}]" style="width: 15px;height: 15px;margin-top: 3px;" value="0" {if condition="$vo.value==0"}checked="checked"{/if}></label>
                                        <tips>{:__('When opening the ordering app, you can use WeChat Pay function after creating an order')}</tips><div></div>
                                        {elseif condition="$vo.name=='price_status'"}
                                        <label style="margin-top: 5px;margin-left: 10px;">{:__('display')}<input type="radio" name="row[config{$vo.id}]" style="width: 15px;height: 15px;margin-top: 3px;" value="1" {if condition="$vo.value==1"}checked="checked"{/if}></label>
                                        <label style="margin-left: 10px;">{:__('hide')}<input type="radio" name="row[config{$vo.id}]" style="width: 15px;height: 15px;margin-top: 3px;" value="0" {if condition="$vo.value==0"}checked="checked"{/if}></label>
                                        <tips>{:__('When hiding the price, the ordering app does not display the product price')}</tips><div></div>
                                        {elseif condition="$vo.name=='speed'"}
                                        <input type="number" class="form-control" name="row[config{$vo.id}]" value="{$vo.value}">
                                        <tips>{:__('You can control the scrolling speed of the ordering announcement through this setting')}</tips><div></div>
                                        {else/}
                                        <textarea class="form-control editor" name="row[config{$vo.id}]" rows="10">{$vo.value}</textarea>
                                        {/if}
                                    </div>
                            </div>

                            {/if}
                            {/foreach}
                            <button type="button" data-id="edit-form" class="sub_btn btn btn-success btn-embossed" style="bottom: -50px;">{:__('OK')}</button>
                            </form>
                        </div>
                    </div>
                </div>

            </div>
        </div>

    </div>
</div>
</div>